package com.lucweb.entity;

import javax.persistence.*;

@Entity
@Table(name = "task_material", schema = "firesystem", catalog = "")
public class TaskMaterial {
    private int id;
    private String materialName;
    private String model;
    private String manufacturer;
    private String counts;
    private String ghsdz;
    private String ghsdh;
    private String shdz;
    private String wlgs;
    private String remarks;
    private String buyStatus;
    private Integer buyId;

    @Id
    @Column(name = "id", nullable = false)
    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    @Basic
    @Column(name = "materialName", nullable = true, length = 255)
    public String getMaterialName() {
        return materialName;
    }

    public void setMaterialName(String materialName) {
        this.materialName = materialName;
    }

    @Basic
    @Column(name = "model", nullable = true, length = 255)
    public String getModel() {
        return model;
    }

    public void setModel(String model) {
        this.model = model;
    }

    @Basic
    @Column(name = "manufacturer", nullable = true, length = 255)
    public String getManufacturer() {
        return manufacturer;
    }

    public void setManufacturer(String manufacturer) {
        this.manufacturer = manufacturer;
    }

    @Basic
    @Column(name = "counts", nullable = true, length = 255)
    public String getCounts() {
        return counts;
    }

    public void setCounts(String counts) {
        this.counts = counts;
    }

    @Basic
    @Column(name = "ghsdz", nullable = true, length = 255)
    public String getGhsdz() {
        return ghsdz;
    }

    public void setGhsdz(String ghsdz) {
        this.ghsdz = ghsdz;
    }

    @Basic
    @Column(name = "ghsdh", nullable = true, length = 255)
    public String getGhsdh() {
        return ghsdh;
    }

    public void setGhsdh(String ghsdh) {
        this.ghsdh = ghsdh;
    }

    @Basic
    @Column(name = "shdz", nullable = true, length = 255)
    public String getShdz() {
        return shdz;
    }

    public void setShdz(String shdz) {
        this.shdz = shdz;
    }

    @Basic
    @Column(name = "wlgs", nullable = true, length = 255)
    public String getWlgs() {
        return wlgs;
    }

    public void setWlgs(String wlgs) {
        this.wlgs = wlgs;
    }

    @Basic
    @Column(name = "remarks", nullable = true, length = 255)
    public String getRemarks() {
        return remarks;
    }

    public void setRemarks(String remarks) {
        this.remarks = remarks;
    }

    @Basic
    @Column(name = "buyStatus", nullable = true, length = 255)
    public String getBuyStatus() {
        return buyStatus;
    }

    public void setBuyStatus(String buyStatus) {
        this.buyStatus = buyStatus;
    }

    @Basic
    @Column(name = "buyId", nullable = true)
    public Integer getBuyId() {
        return buyId;
    }

    public void setBuyId(Integer buyId) {
        this.buyId = buyId;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        TaskMaterial that = (TaskMaterial) o;

        if (id != that.id) return false;
        if (materialName != null ? !materialName.equals(that.materialName) : that.materialName != null) return false;
        if (model != null ? !model.equals(that.model) : that.model != null) return false;
        if (manufacturer != null ? !manufacturer.equals(that.manufacturer) : that.manufacturer != null) return false;
        if (counts != null ? !counts.equals(that.counts) : that.counts != null) return false;
        if (ghsdz != null ? !ghsdz.equals(that.ghsdz) : that.ghsdz != null) return false;
        if (ghsdh != null ? !ghsdh.equals(that.ghsdh) : that.ghsdh != null) return false;
        if (shdz != null ? !shdz.equals(that.shdz) : that.shdz != null) return false;
        if (wlgs != null ? !wlgs.equals(that.wlgs) : that.wlgs != null) return false;
        if (remarks != null ? !remarks.equals(that.remarks) : that.remarks != null) return false;
        if (buyStatus != null ? !buyStatus.equals(that.buyStatus) : that.buyStatus != null) return false;
        if (buyId != null ? !buyId.equals(that.buyId) : that.buyId != null) return false;

        return true;
    }

    @Override
    public String toString() {
        return "TaskMaterial{" +
                "id=" + id +
                ", materialName='" + materialName + '\'' +
                ", model='" + model + '\'' +
                ", manufacturer='" + manufacturer + '\'' +
                ", counts='" + counts + '\'' +
                ", ghsdz='" + ghsdz + '\'' +
                ", ghsdh='" + ghsdh + '\'' +
                ", shdz='" + shdz + '\'' +
                ", wlgs='" + wlgs + '\'' +
                ", remarks='" + remarks + '\'' +
                ", buyStatus='" + buyStatus + '\'' +
                ", buyId=" + buyId +
                '}';
    }

    @Override
    public int hashCode() {
        int result = id;
        result = 31 * result + (materialName != null ? materialName.hashCode() : 0);
        result = 31 * result + (model != null ? model.hashCode() : 0);
        result = 31 * result + (manufacturer != null ? manufacturer.hashCode() : 0);
        result = 31 * result + (counts != null ? counts.hashCode() : 0);
        result = 31 * result + (ghsdz != null ? ghsdz.hashCode() : 0);
        result = 31 * result + (ghsdh != null ? ghsdh.hashCode() : 0);
        result = 31 * result + (shdz != null ? shdz.hashCode() : 0);
        result = 31 * result + (wlgs != null ? wlgs.hashCode() : 0);
        result = 31 * result + (remarks != null ? remarks.hashCode() : 0);
        result = 31 * result + (buyStatus != null ? buyStatus.hashCode() : 0);
        result = 31 * result + (buyId != null ? buyId.hashCode() : 0);
        return result;
    }
}
